home *** CD-ROM | disk | FTP | other *** search
/ Amiga Collections: MegaDisc / MegaDisc 13 (1989)(MegaDisc Digital Publishing)(AU)[b missing files][WB].zip / MegaDisc 13 (1989)(MegaDisc Digital Publishing)(AU)[b missing files][WB].adf / PROGRAMS / Bmapviewer < prev    next >
Text File  |  1989-05-22  |  2KB  |  106 lines

  1. startit:
  2. PRINT:PRINT
  3. PRINT "BMAP VIEWER (Options 1 - 4 assume your .bmaps are in directory"
  4. PRINT "             BMAPS on the same disk as this program - If they"
  5. PRINT "             are on another disk or in another directory use 5."
  6. PRINT
  7. RESTORE
  8.  
  9. DATA DISKFONT,DOS,GRAPHICS,EXEC,OTHER,QUIT,END
  10. READ f$
  11. f=0
  12. WHILE f$<>"END"
  13. f=f+1
  14. IF f$="OTHER" THEN
  15. PRINT f; " OTHER"
  16. ELSEIF f$="QUIT" THEN
  17. PRINT f; " QUIT"
  18. ELSE
  19. PRINT f;" bmaps/";f$;".bmap"
  20. END IF
  21. READ f$
  22. WEND
  23. ch=0
  24. PRINT
  25. WHILE ch<1 OR ch>f
  26. INPUT "Your choice";ch
  27. WEND
  28. IF ch<f-1 THEN
  29. RESTORE
  30. FOR j=1 TO ch
  31. READ f$
  32. NEXT j
  33. nam$="bmaps/"+f$+".bmap"
  34. ELSEIF ch=f-1 THEN
  35. PRINT "Enter full .bmap file name: ";
  36. LINE INPUT nam$
  37. ELSE
  38. CLS
  39. END
  40. END IF
  41. showit:
  42. INPUT "Output to 1. Screen or 2. Printer";op
  43. IF op<1 OR op>2 THEN showit
  44.  
  45. CLS
  46. ld=1
  47. OPEN nam$ FOR INPUT AS #1
  48. bfile$=INPUT$(LOF(1),1)
  49. CLOSE #1
  50. sname=1
  51. n$=CHR$(0)
  52. WHILE sname<LEN(bfile$)
  53. ename=INSTR(MID$(bfile$,sname),n$)
  54. IF op=1 THEN
  55. PRINT MID$(bfile$,sname,ename-1);TAB(25);
  56. ELSE
  57. LPRINT MID$(bfile$,sname,ename-1);TAB(25);
  58. END IF
  59. ofset=CVI(MID$(bfile$,ename+sname,2))
  60. IF op=1 THEN
  61. PRINT USING "#### ";ofset;
  62. ELSE
  63. LPRINT USING "#### ";ofset;
  64. END IF
  65. sep$=" "
  66. parmpt=ename+sname+2
  67. parm=ASC(MID$(bfile$,parmpt))
  68. WHILE parm<>0
  69. parm=parm-1
  70. IF parm>7 THEN
  71. handle$="A"+CHR$(48+parm-8)
  72. ELSE
  73. handle$="D"+CHR$(48+parm)
  74. END IF
  75. IF op=1 THEN
  76. PRINT sep$;handle$;
  77. ELSE
  78. LPRINT sep$;handle$;
  79. END IF
  80. sep$=","
  81. parmpt=parmpt+1
  82. parm=ASC(MID$(bfile$,parmpt))
  83. WEND
  84. IF op=1 THEN
  85. PRINT:  ld =ld+1
  86. ELSE
  87. LPRINT
  88. END IF
  89. IF ld=20 THEN GOSUB continue
  90. sname=parmpt+1
  91. WEND
  92. IF op=1 THEN
  93. GOSUB continue
  94.  
  95. ELSE
  96. LPRINT CHR$(12)
  97. END IF
  98. GOTO startit
  99. continue:
  100.  LOCATE 22,22 
  101. INPUT "   PRESS ENTER TO CONTINUE";con$
  102. ld=1
  103.  
  104. CLS
  105. RETURN
  106.